/*
 * Copyright (c) 2006, 2021, webrx.cn All rights reserved.
 *
 */
package cn.webrx;

/**
 * <p>Project: javaseapp - Var1
 * <p>Powered by webrx On 2021-07-27 10:45:13
 * <p>Created by IntelliJ IDEA
 *
 * @author webrx [webrx@126.com]
 * @version 1.0
 * @since 16
 */
public class Var2 {
    public static void main(String[] args) {
      /*
      8大基本类型
      byte short int long float double char boolean
        整型 byte short int long
        浮点 float double
        字符 char  'a'
        布尔 boolean
       */
        byte i = -128; //127 - -128
        short s = 3223;
        int age = 18;
        byte aa = 18;

        //在数字后添加L f d
        long n = 24L;

        float f1 = 1.2f;
        double f2 = 1.2D;
        double f3 = 10d;
        System.out.println(f3);
        System.out.printf("%.2f", Math.PI);

        //字符型  char myc = 'a';
        char c1 = 'a';
        char c2 = 65;
        System.out.println();
        System.out.println(c1);//a
        System.out.println(c2);//A

        //字符串对象
        String s1 = "hello";

        boolean b1 = true;
        boolean b2 = false;
        boolean b3 = !true;
        System.out.println(b1);
        System.out.println(b2);
        System.out.println(b3);
        System.out.println(b3 && b2);

    }
}
